package gov.pbc.nn.kjgl.task.dao;

import java.util.Collection;
import java.util.HashMap;
import java.util.Map;

import org.springframework.stereotype.Component;

import gov.pbc.nn.core.dao.AbstractHibernateDao;
import gov.pbc.nn.kjgl.task.entity.TaskBranchUser;

@Component("taskDao")
public class TaskDao extends AbstractHibernateDao {

	
	public Collection<TaskBranchUser> getBranchUsersbyTaskId(String TaskEntityId)
			throws Exception {
		Map<String, Object> map = new HashMap<String, Object>();
		map.put("taskEntityId", TaskEntityId);
		return this.query(" from " + TaskBranchUser.class.getName()
				+ " where taskEntityId=:taskEntityId and invalid=false ", map);
	}

}
